Help diagnose flaky test
authorAlex Crichton <alex@alexcrichton.com>
Sun, 29 Mar 2015 06:30:39 +0000 (23:30 -0700)
committerAlex Crichton <alex@alexcrichton.com>
Sun, 29 Mar 2015 06:30:39 +0000 (23:30 -0700)
src/cargo/ops/cargo_rustc/mod.rs
tests/test_cargo_bench.rs
tests/test_cargo_test.rs

index d5d6d170b127caa7487f40603ab697f7d01a8dfc..c553547e7924c313b2a598f62616c701c8939f78 100644 (file)
@@ -375,12 +375,12 @@ fn rustc(package: &Package, target: &Target, profile: &Profile,
                                                 .to_str().unwrap()
                                                 .replace(&real_name, &crate_name));
                 try!(fs::rename(&src, &dst).chain_error(|| {
-                    human(format!("could not rename crate {:?}", src))
+                    internal(format!("could not rename crate {:?}", src))
                 }));
             }
 
             try!(fs::rename(&rustc_dep_info_loc, &dep_info_loc).chain_error(|| {
-                human(format!("could not rename dep info: {:?}",
+                internal(format!("could not rename dep info: {:?}",
                               rustc_dep_info_loc))
             }));
             try!(fingerprint::append_current_dir(&dep_info_loc, &cwd));
index 7f2231f6fb0ea8797d2e88a839813becb4797c07..54de09ce944ab826d64907dbe37e3c5305299306 100644 (file)
@@ -648,7 +648,7 @@ test!(bin_there_for_integration {
             }
         "#);
 
-    let output = p.cargo_process("bench").exec_with_output().unwrap();
+    let output = p.cargo_process("bench").arg("-v").exec_with_output().unwrap();
     let output = str::from_utf8(&output.stdout).unwrap();
     assert!(output.contains("main_bench ... bench:         0 ns/iter (+/- 0)"),
                             "no main_bench\n{}",
index db11838b1dce9b70d1c8dd5eb9832065a3202622..401ca3ba5fe8498fe68ebe6968435ac72514c936 100644 (file)
@@ -637,7 +637,7 @@ test!(bin_there_for_integration {
             }
         "#);
 
-    let output = p.cargo_process("test").exec_with_output().unwrap();
+    let output = p.cargo_process("test").arg("-v").exec_with_output().unwrap();
     let output = str::from_utf8(&output.stdout).unwrap();
     assert!(output.contains("main_test ... ok"), "no main_test\n{}", output);
     assert!(output.contains("test_test ... ok"), "no test_test\n{}", output);